{% extends 'base.html' %}
{% block content %}
    <div class="text-center">
        <h1>{{ today }}申请人员名单</h1>
    </div>

    <div style="margin:50px 0px 100px" class="text-center">
        <h4>当前登录用户：{{ current_user.name }}</h4>
        <h4>院系：{{ current_user.xy }}</h4>
    </div>

    <div class="container">
        <div class="row clearfix">
            <div class="col-md-12 column">
                <table class="table table-bordered">
                    <thead>
                    <tr>
                        <th>姓名</th>
                        <th>学号</th>
                        <th>学院</th>
                        <th>班级</th>
                        <!-- <th>学历证明</th>
                        <th>学籍证明</th> -->
                        <th>待办事项</th>
                        <th>申请时间</th>
                        <th>申请理由</th>
                    </tr>
                    </thead>
                    <tbody>

                    {% for name in names %}
                        {% if name.created_date == today %}
                            <tr>
                                <td>{{ name.xm }}</td>
                                <td>{{ name.xh }}</td>
                                <td>{{ name.xy }}</td>
                                <td>{{ name.bj }}</td>
                                {% if name.zt == '学历' %}
                                        <td>
                                            <a href="{{ url_for('xueli',name_id=name.id) }}" target="_blank">学历证明</a>
                                        </td>
                                    {% elif name.zt == '学籍' %}
                                        <td>
                                            <a href="{{ url_for('xueji',name_id=name.id) }}" target="_blank">在校生学籍证明</a>
                                        </td>
                                    {% elif name.zt == '注销' %}
                                        <td>
                                            <a href="{{ url_for('zhuxiaoxueji',name_id=name.id) }}" target="_blank">注销学籍</a>
                                        </td>
                                    {% elif name.zt == '保留学籍' %}
                                        <td>
                                            <a href="{{ url_for('xuejilixiaoqingdan',name_id=name.id) }}"target="_blank">1.保留学籍离校清单</a>
                                            <a href="{{ url_for('xuejishenqingbiao',name_id=name.id) }}"target="_blank">2.保留学籍申请表</a>
                                            <a href="{{ url_for('xuejitongzhishu',name_id=name.id) }}"target="_blank">3.保留学籍通知书</a>
                                        </td>
                                    {% elif name.zt == '复学' %}
                                        <td>
                                            <a href="{{ url_for('fuxueshenqing',name_id=name.id) }}"target="_blank">1.复学申请</a>
                                            <a href="{{ url_for('fuxueruban',name_id=name.id) }}"target="_blank">2.复学入班通知单</a>
                                        </td>
                                    {% elif name.zt == '退学' %}
                                        <td>
                                            <a href="{{ url_for('tuixueshenqing',name_id=name.id) }}"target="_blank">1.退学申请</a>
                                            <a href="{{ url_for('tuixue_lixiaoqingdan',name_id=name.id) }}"target="_blank">2.退学离校清单</a>
                                            <a href="{{ url_for('tuixue_tongzhi',name_id=name.id) }}"target="_blank">3.退学通知书</a>
                                        </td>
                                    {% elif name.zt == '休学' %}
                                        <td>
                                            <a href="{{ url_for('xiuxueshenqing',name_id=name.id) }}"target="_blank">1.休学申请</a>
                                            <a href="{{ url_for('xiuxuelixiaoqingdan',name_id=name.id) }}"target="_blank">2.休学离校清单</a>
                                            <a href="{{ url_for('xiuxuetongzhi',name_id=name.id) }}"target="_blank">3.休学通知书</a>
                                        </td>
                                    {% elif name.zt == '转专业' %}
                                        <td>
                                            <a href="{{ url_for('zhuanyeshenqing',name_id=name.id) }}"target="_blank">1.转专业申请</a>
                                            <a href="{{ url_for('zhuanyeruban',name_id=name.id) }}"target="_blank">2.转专业入班</a>
                                        </td>
                                {% endif %}
                                <td>{{ name.created_date }}</td>
                                <td>{{ name.reason }}</td>
                            </tr>
                        {% endif %}
                    {% endfor %}
                    </tbody>
                </table>
            </div>
        </div>
    </div>

{% endblock %}